TGT=netdrive
CC=gcc
FILES = backup.o netdrive.o amazon.o cJSON.o

CFLAGS += -Wall -Wunused -g -O2

all	:	netdrive

netdrive	:	$(FILES)
	$(CC) $(CFLAGS) $(FILES) -o $@ $(EXTRA_LDFLAGS) $(LDFLAGS) -lm -lcurl -lsqlite3 -lpthread
	@echo "make $@ finished on `date` "

%.o	: %.c %.h
	$(CC) $(CFLAGS) -c $<

clean:
	rm -f *.o
	rm -f netdrive
